#region Using directives
using System;
#endregion

namespace SharpWind.Math
{
	/*public class Matrix
	{
		#region Fields

		private float a1;
		
		private float a2;
		
		private float a3;
		
		private float a4;
		
		private float b1;
		
		private float b2;
		
		private float b3;
		
		private float b4;
		
		private float c1;
		
		private float c2;
		
		private float c3;
		
		private float c4;
		
		private float d1;
		
		private float d2;
		
		private float d3;
		
		private float d4;

		#endregion

		#region Constructors

		public Matrix()
		{
			this.a1 = 0f; this.b1 = 0f; this.c1 = 0f; this.d1 = 0f;
			this.a2 = 0f; this.b2 = 0f; this.c2 = 0f; this.d2 = 0f;
			this.a3 = 0f; this.b3 = 0f; this.c3 = 0f; this.d3 = 0f;
			this.a4 = 0f; this.b4 = 0f; this.c4 = 0f; this.d4 = 0f;
		}

		public Matrix( float a1, float a2, float a3, float a4,
					   float b1, float b2, float b3, float b4,
					   float c1, float c2, float c3, float c4,
					   float d1, float d2, float d3, float d4 )
		{
			this.a1 = a1; this.b1 = b1; this.c1 = c1; this.d1 = d1;
			this.a2 = a2; this.b2 = b2; this.c2 = c2; this.d2 = d2;
			this.a3 = a3; this.b3 = b3; this.c3 = c3; this.d3 = d3;
			this.a4 = a4; this.b4 = b4; this.c4 = c4; this.d4 = d4;
		}

		internal Matrix( Microsoft.DirectX.Matrix matrix )
		{
			this.m11 = matrix.M11; this.m12 = matrix.M12; this.m13 = matrix.M13; this.m14 = matrix.M14;
			this.m21 = matrix.M21; this.m22 = matrix.M22; this.m23 = matrix.M23; this.m24 = matrix.M24;
			this.m31 = matrix.M31; this.m32 = matrix.M32; this.m33 = matrix.M33; this.m34 = matrix.M34;
			this.m41 = matrix.M41; this.m42 = matrix.M42; this.m43 = matrix.M43; this.m44 = matrix.M44;
		}

		#endregion

		#region Methods

		public static Matrix Invert( Matrix matrix )
		{
			Matrix invert = new Matrix();
			invert.m11 = matrix.m23 * matrix.m34 * matrix.m42 - matrix.m24 * matrix.m33 * matrix.m42 + matrix.m24 * matrix.m32 * matrix.m43 - matrix.m22 * matrix.m34 * matrix.m43 - matrix.m23 * matrix.m32 * matrix.m44 + matrix.m22 * matrix.m33 * matrix.m44;
			invert.m12 = matrix.m14 * matrix.m33 * matrix.m42 - matrix.m13 * matrix.m34 * matrix.m42 - matrix.m14 * matrix.m32 * matrix.m43 + matrix.m12 * matrix.m34 * matrix.m43 + matrix.m13 * matrix.m32 * matrix.m44 - matrix.m12 * matrix.m33 * matrix.m44;
			invert.m13 = matrix.m13 * matrix.m24 * matrix.m42 - matrix.m14 * matrix.m23 * matrix.m42 + matrix.m14 * matrix.m22 * matrix.m43 - matrix.m12 * matrix.m24 * matrix.m43 - matrix.m13 * matrix.m22 * matrix.m44 + matrix.m12 * matrix.m23 * matrix.m44;
			invert.m14 = matrix.m14 * matrix.m23 * matrix.m32 - matrix.m13 * matrix.m24 * matrix.m32 - matrix.m14 * matrix.m22 * matrix.m33 + matrix.m12 * matrix.m24 * matrix.m33 + matrix.m13 * matrix.m22 * matrix.m34 - matrix.m12 * matrix.m23 * matrix.m34;

			invert.m21 = matrix.m24 * matrix.m33 * matrix.m41 - matrix.m23 * matrix.m34 * matrix.m41 - matrix.m24 * matrix.m31 * matrix.m43 + matrix.m21 * matrix.m34 * matrix.m43 + matrix.m23 * matrix.m31 * matrix.m44 - matrix.m21 * matrix.m33 * matrix.m44;
			invert.m22 = matrix.m13 * matrix.m34 * matrix.m41 - matrix.m14 * matrix.m33 * matrix.m41 + matrix.m14 * matrix.m31 * matrix.m43 - matrix.m11 * matrix.m34 * matrix.m43 - matrix.m13 * matrix.m31 * matrix.m44 + matrix.m11 * matrix.m33 * matrix.m44;
			invert.m23 = matrix.m14 * matrix.m23 * matrix.m41 - matrix.m13 * matrix.m24 * matrix.m41 - matrix.m14 * matrix.m21 * matrix.m43 + matrix.m11 * matrix.m24 * matrix.m43 + matrix.m13 * matrix.m21 * matrix.m44 - matrix.m11 * matrix.m23 * matrix.m44;
			invert.m24 = matrix.m13 * matrix.m24 * matrix.m31 - matrix.m14 * matrix.m23 * matrix.m31 + matrix.m14 * matrix.m21 * matrix.m33 - matrix.m11 * matrix.m24 * matrix.m33 - matrix.m13 * matrix.m21 * matrix.m34 + matrix.m11 * matrix.m23 * matrix.m34;

			invert.m31 = matrix.m22 * matrix.m34 * matrix.m41 - matrix.m24 * matrix.m32 * matrix.m41 + matrix.m24 * matrix.m31 * matrix.m42 - matrix.m21 * matrix.m34 * matrix.m42 - matrix.m22 * matrix.m31 * matrix.m44 + matrix.m21 * matrix.m32 * matrix.m44;
			invert.m32 = matrix.m14 * matrix.m32 * matrix.m41 - matrix.m12 * matrix.m34 * matrix.m41 - matrix.m14 * matrix.m31 * matrix.m42 + matrix.m11 * matrix.m34 * matrix.m42 + matrix.m12 * matrix.m31 * matrix.m44 - matrix.m11 * matrix.m32 * matrix.m44;
			invert.m33 = matrix.m12 * matrix.m24 * matrix.m41 - matrix.m14 * matrix.m22 * matrix.m41 + matrix.m14 * matrix.m21 * matrix.m42 - matrix.m11 * matrix.m24 * matrix.m42 - matrix.m12 * matrix.m21 * matrix.m44 + matrix.m11 * matrix.m22 * matrix.m44;
			invert.m34 = matrix.m14 * matrix.m22 * matrix.m31 - matrix.m12 * matrix.m24 * matrix.m31 - matrix.m14 * matrix.m21 * matrix.m32 + matrix.m11 * matrix.m24 * matrix.m32 + matrix.m12 * matrix.m21 * matrix.m34 - matrix.m11 * matrix.m22 * matrix.m34;

			invert.m41 = matrix.m23 * matrix.m32 * matrix.m41 - matrix.m22 * matrix.m33 * matrix.m41 - matrix.m23 * matrix.m31 * matrix.m42 + matrix.m21 * matrix.m33 * matrix.m42 + matrix.m22 * matrix.m31 * matrix.m43 - matrix.m21 * matrix.m32 * matrix.m43;
			invert.m42 = matrix.m12 * matrix.m33 * matrix.m41 - matrix.m13 * matrix.m32 * matrix.m41 + matrix.m13 * matrix.m31 * matrix.m42 - matrix.m11 * matrix.m33 * matrix.m42 - matrix.m12 * matrix.m31 * matrix.m43 + matrix.m11 * matrix.m32 * matrix.m43;
			invert.m43 = matrix.m13 * matrix.m22 * matrix.m41 - matrix.m12 * matrix.m23 * matrix.m41 - matrix.m13 * matrix.m21 * matrix.m42 + matrix.m11 * matrix.m23 * matrix.m42 + matrix.m12 * matrix.m21 * matrix.m43 - matrix.m11 * matrix.m22 * matrix.m43;
			invert.m44 = matrix.m12 * matrix.m23 * matrix.m31 - matrix.m13 * matrix.m22 * matrix.m31 + matrix.m13 * matrix.m21 * matrix.m32 - matrix.m11 * matrix.m23 * matrix.m32 - matrix.m12 * matrix.m21 * matrix.m33 + matrix.m11 * matrix.m22 * matrix.m33;
			
			return invert * ( 1 / matrix.Determinant );
		}

		public static Matrix Translation( Vector3 translation )
		{
			return new Matrix( )
		}

		internal static Microsoft.DirectX.Matrix ConvertToDirectXMatrix( Matrix matrix )
		{
			Microsoft.DirectX.Matrix m = new Microsoft.DirectX.Matrix();
			matrix.m11 = matrix.M11; matrix.m12 = matrix.M12; matrix.m13 = matrix.M13; matrix.m14 = matrix.M14;
			matrix.m21 = matrix.M21; matrix.m22 = matrix.M22; matrix.m23 = matrix.M23; matrix.m24 = matrix.M24;
			matrix.m31 = matrix.M31; matrix.m32 = matrix.M32; matrix.m33 = matrix.M33; matrix.m34 = matrix.M34;
			matrix.m41 = matrix.M41; matrix.m42 = matrix.M42; matrix.m43 = matrix.M43; matrix.m44 = matrix.M44;

			return m;
		}

		#endregion

		#region Operators

		public static Matrix operator +( Matrix matrix1, Matrix matrix2 )
		{
			return new Matrix
			(
				matrix1.m11 + matrix2.m11, matrix1.m12 + matrix2.m12, matrix1.m13 + matrix2.m13, matrix1.m14 + matrix2.m14,
				matrix1.m21 + matrix2.m21, matrix1.m22 + matrix2.m22, matrix1.m23 + matrix2.m23, matrix1.m24 + matrix2.m24,
				matrix1.m31 + matrix2.m31, matrix1.m32 + matrix2.m32, matrix1.m33 + matrix2.m33, matrix1.m34 + matrix2.m34,
				matrix1.m41 + matrix2.m41, matrix1.m42 + matrix2.m42, matrix1.m43 + matrix2.m43, matrix1.m44 + matrix2.m44 
			);
		}

		#endregion

		#region Properties

		public static Matrix Identity
		{
			get
			{
				Matrix m = new Matrix();
				m.A1 = m.B2 = m.C3 = m.D4 = 1.0f;

				return m;
			}
		}

		public float Determinant
		{
			get
			{
				return this.A4 * this.B3 * this.C2 * this.D1 -
						this.A3 * this.B4 * this.C2 * this.D1 -
						this.A4 * this.B2 * this.C3 * D1 +
						this.A2 * this.B4 * this.C3 * D1 +
						this.A3 * this.B2 * this.C4 * D1 -
						this.A2 * this.B3 * this.C4 * D1 -
						this.A4 * this.B3 * this.C1 * D2 +
						this.A3 * this.B4 * this.C1 * D2 +
						this.A4 * this.B1 * this.C3 * D2 -
						this.A1 * this.B4 * this.C3 * D2 -
						this.A3 * this.B1 * this.C4 * D2 +
						this.A1 * this.B3 * this.C4 * D2 +
						this.A4 * this.B2 * this.C1 * D3 -
						this.A2 * this.B4 * this.C1 * D3 -
						this.A4 * this.B1 * this.C2 * D3 +
						this.A1 * this.B4 * this.C2 * D3 +
						this.A2 * this.B1 * this.C4 * D3 -
						this.A1 * this.B2 * this.C4 * D3 -
						this.A3 * this.B2 * this.C1 * D4 +
						this.A2 * this.B3 * this.C1 * D4 +
						this.A3 * this.B1 * C2 * D4 -
						this.A1 * this.B3 * C2 * D4 -
						this.A2 * this.B1 * C3 * D4 +
						this.A1 * this.B2 * C3 * D4;
			}
		}

		public Vector3 RightVector
		{
			get
			{
				return new Vector3
				(
					this.a1,
					this.b1,
					this.c1
				);
			}
			set
			{
				this.a1 = value.X;
				this.b1 = value.Y;
				this.c1 = value.Z;
			}
		}

		public Vector3 UpVector
		{
			get
			{
				return new Vector3
				(
					this.a2,
					this.b2,
					this.c2
				);
			}
			set
			{
				this.a2 = value.X;
				this.b2 = value.Y;
				this.c2 = value.Z;
			}
		}

		public Vector3 LookVector
		{
			get
			{
				return new Vector3
				(
					this.a3,
					this.b3,
					this.c3
				);
			}
			set
			{
				this.a3 = value.X;
				this.b3 = value.Y;
				this.c3 = value.Z;
			}
		}

		public Vector3 TranslationVector
		{
			get
			{
				return new Vector3
				(
					this.d1,
					this.d2,
					this.d3
				);
			}
			set
			{
				this.d1 = value.X;
				this.d2 = value.Y;
				this.d3 = value.Z;
			}
		}

		public float A1
		{
			get
			{
				return this.a1;
			}
			set
			{
				this.a1 = value;
			}
		}

		public float A2
		{
			get
			{
				return this.a2;
			}
			set
			{
				this.a2 = value;
			}
		}

		public float A3
		{
			get
			{
				return this.a3;
			}
			set
			{
				this.a3 = value;
			}
		}

		public float A4
		{
			get
			{
				return this.a4;
			}
			set
			{
				this.a4 = value;
			}
		}

		public float B1
		{
			get
			{
				return this.b1;
			}
			set
			{
				this.b1 = value;
			}
		}

		public float B2
		{
			get
			{
				return this.b2;
			}
			set
			{
				this.b2 = value;
			}
		}

		public float B3
		{
			get
			{
				return this.b3;
			}
			set
			{
				this.b3 = value;
			}
		}

		public float B4
		{
			get
			{
				return this.b4;
			}
			set
			{
				this.b4 = value;
			}
		}

		public float C1
		{
			get
			{
				return this.c1;
			}
			set
			{
				this.c1 = value;
			}
		}

		public float c2
		{
			get
			{
				return this.c2;
			}
			set
			{
				this.c2 = value;
			}
		}

		public float C3
		{
			get
			{
				return this.c3;
			}
			set
			{
				this.c3 = value;
			}
		}

		public float C4
		{
			get
			{
				return this.c4;
			}
			set
			{
				this.c4 = value;
			}
		}

		public float D1
		{
			get
			{
				return this.d1;
			}
			set
			{
				this.d1 = value;
			}
		}

		public float D2
		{
			get
			{
				return this.d2;
			}
			set
			{
				this.d2 = value;
			}
		}

		public float D3
		{
			get
			{
				return this.d3;
			}
			set
			{
				this.d3 = value;
			}
		}

		public float D4
		{
			get
			{
				return this.d4;
			}
			set
			{
				this.d4 = value;
			}
		}

		#endregion
	}*/
}